import request from '@/utils/request'

//药品不良事件
export function addMedicineEvent(query) {
  return request({
    url: 'adverse/medicine/addMedicineEvent',
    method: 'post',
    data: query
  })
}

//药品不良事件
export function editMedicineEvent(query) {
  return request({
    url: 'adverse/medicine/editMedicineEvent',
    method: 'post',
    data: query
  })
}


//药品不良事件
export function medicineQueryPage(query) {
  return request({
    url: 'adverse/medicine/queryPage',
    method: 'post',
    data: query
  })
}


//器械不良事件
export function addApparatusEvent(query) {
  return request({
    url: 'adverse/apparatus/addApparatusEvent',
    method: 'post',
    data: query
  })
}

//医疗不良事件
export function apparatusEventQueryPage(query) {
  return request({
    url: 'adverse/apparatus/queryPage',
    method: 'post',
    data: query
  })
}

//医疗不良事件删除
export function deleteTreatmentEvent(query) {
  return request({
    url: 'adverse/treatment/deleteTreatmentEvent',
    method: 'post',
    data: query
  })
}


//器械不良事件删除
export function deleteApparatusEvent(query) {
  return request({
    url: 'adverse/apparatus/deleteApparatusEvent',
    method: 'post',
    data: query
  })
}

//药品不良事件删除
export function deleteMedicineEvent(query) {
  return request({
    url: 'adverse/medicine/deleteMedicineEvent',
    method: 'post',
    data: query
  })
}


//医疗不良事件
export function addTreatment(query) {
  return request({
    url: 'adverse/treatment/addTreatment',
    method: 'post',
    data: query
  })
}

//医疗不良事件-修改
export function editTreatment(query) {
  return request({
    url: 'adverse/treatment/editTreatmentEvent',
    method: 'post',
    data: query
  })
}

//医疗器械不良事件-修改
export function editApparatus(query) {
  return request({
    url: '/adverse/apparatus/editApparatusEvent',
    method: 'post',
    data: query
  })
}

//医疗不良事件
export function treatmentQueryPage(query) {
  return request({
    url: 'adverse/treatment/queryPage',
    method: 'post',
    data: query
  })
}



// 新增或者修改用户
export function dealUser(data) {
  return request({
    url: 'api/account/dealUser',
    method: 'post',
    data: data
  })
}
//修改就诊人
export function doDefaultUser(data) {
  return request({
    url: 'api/account/doDefaultUser',
    method: 'post',
    params: data
  })
}


// 删除科室信息 科室信息
export function deleteUser(data) {
  return request({
    url: 'api/account/'+data,
    method: 'DELETE',
  })
}


